<%-- 
    Document   : top
    Created on : Jun 1, 2012, 12:26:05 PM
    Author     : Owner
--%>

<%@include file="/jsp/includeHead.jsp" %>

<html:html>
    <head>

    </head>
    <body>
        <div id="header">
            <div class="headerMain">
                <div class="headerMainRight">
                    <div class="logo">
                        <a class="show-dashboard" href="#"><img src="images/logo.jpg" alt="logo"/>
                        </a>
                    </div>
                    <html:form action="/menuAction" method="request">
                        <div class="searchPanel">
                            <div class="searching">                                
                                Category:<html:select property="category" style="width:160px">
                                    <html:option value="0">--Select--</html:option>
                                    <html:options collection="categoryMap" property="key" labelProperty="value"/>
                                </html:select>
                                <html:text property="searchProduct" style="height:30px; width:180px;"/>

                            </div>
                            <div class="search">
                                <a class="search-product-button" href="#">
                                    <img src="images/icon_search.png" alt="Search Button" onmouseover="src='images/search-hover-icon.jpeg'" onmouseout="src='images/icon_search.png'"/></a>
                            </div>
                        </div>
                    </html:form>
                    <div class="welcomeGuest">
                        <% Long userId = Long.parseLong(String.valueOf(session.getAttribute("loginUserId")));
                                    Long roleId = Long.parseLong(String.valueOf(session.getAttribute("loginRoleId")));
                                    if (userId > 0 && roleId == 0) {%>
                        <span> Welcome Guest.</span>
                        <p>
                            <a class="show-login" href="./userAccount.do?action=showUserLogin">Login</a>
                            |
                            <a class="show-register-user" href="./userAccount.do?action=showUserRegistration">Register</a>
                        </p>
                        <%} else {%>
                        <span> Welcome <%= session.getAttribute("loginUsername")%>.</span>
                        <p>
                            <a class="show-myaccount" href="./userAccount.do?action=showAccountDashboard">My Account</a>
                            |
                            <a class="logout" href="./userAccount.do?action=logout">Logout</a>
                        </p>

                        <%}%>
                    </div>
                    <div class="myCart">
                        <a id="mainqty" class="itemAmt" href="./product.do?action=showCart"> 0 </a>
                        <div class="wrap">
                            <span>My Cart</span>
                            <p>
                                <a id="mainprice" class="lessPadd" href="#">
                                    (
                                    <span class="WebRupee">Rs. </span>
                                    0 )
                                </a>
                            </p>
                        </div>
                    </div>                  


                </div>
            </div>
            <div class="navMenu">
                <ul id="hmenu" class="nav_top-menubar">
                    <li><a href="./menuAction.do?action=showHomeBeforeLogin" >Home</a></li>
                    <li><a href="./menuAction.do?action=showAboutUs" >About Us</a></li>
                    <li><a href="./category.do?action=showCategory" >All Categories</a></li>
                    <li><a href="./menuAction.do?action=showSearchPage" >Search</a></li>
                    <li><a href="./menuAction.do?action=showMyAccount" >My Account</a></li>
                    <li><a href="./product.do?action=showCart" >Cart</a></li>
                    <li><a href="./menuAction.do?action=showContactUs" >Contact Us</a></li>
                </ul>
            </div>
        </div>
    </body>
</html:html>
